from openpyxl import load_workbook
workbook = load_workbook('F:\\python\\第5章\\出库表1.xlsx')
worksheet = workbook['Sheet1']
worksheet.merge_cells(range_string='A1:E1')
workbook.save('F:\\python\\第5章\\合并表.xlsx')
